package demo1;

public class Student {
    public String name;
    public int age;
    public static String school = "bitU";

    public Student(String name, int age){
        this.name = name;
        this.age = age;
    }

    public Student(){

    }

    public void playBasketball(){
        System.out.println(this.name + "正在打球...");
        getSchool();
        System.out.println("学校:" + school);
    }

    public static String getSchool(){
        System.out.println("静态成员方法被调用...");
        return school;
    }

    public static void func(){
        Student student = new Student();
        student.name = "ben";
        student.age = 18;
        student.playBasketball();
    }
}
